home *** CD-ROM | disk | FTP | other *** search
/ Fifty: Elektronik / FIFTY Elektronik (PS_Computer_Vertrieb).iso / ps8 / fty1017 / gepackt.exe / DISK2 / PLOTSRC.EXE / PLGLOB.PAS < prev    next >
Encoding:
Pascal/Delphi Source File  |  1993-11-10  |  4.1 KB  |  167 lines

  1. {$R-,S-,B-,I+}
  2. Unit PLGLOB;
  3.  
  4. Interface
  5.  
  6. uses
  7.   Crt,
  8.   Dos,
  9.   StrTool,
  10.   GEDDEFS,
  11.   LibMan,
  12.   Geotool,
  13.   KEYSCRN,
  14.   PLOTSYS,
  15.   PLOTSTOR,
  16.   Serinout,
  17.   PRNinOut,
  18.   PLSTEUER;
  19.  
  20. CONST
  21.        titel     :Str64= '>>>>   GEDDY-CAD   <<<<';
  22.        titel2    :Str64= 'Plotter-Ausgabe';
  23.  
  24.        ModeWinCol   :Byte =53; {V: magenta , H:cyan   }
  25.        ModeLowCol   :Byte =49; {V: blue    , H:Cyan   }
  26.        ModeNorCol   :Byte =53; {V: magenta , H:cyan   }
  27.        ModeFlpCol   :Byte =94; {V: yellow  , H:magenta}
  28.        ModeHeadCol  :Byte =62; {V: yellow  , H:Cyan   }
  29.        ModeHiCol    :Byte =49;
  30.        MainWinCol   :Byte =green;
  31.        MainHeadCol  :Byte =Yellow;
  32.        MainNorCol   :Byte =Yellow;
  33.        MainLowCol   :Byte =Lightgray;
  34.        MainFlpCol   :Byte =112;
  35.        MainHiCol    :Byte =Crt.LightRed;
  36.        BordCol     :Byte =Lightgray;
  37.        CopyWrCol   :Byte =LightRed;
  38.        TitelCol    :Byte =LightGreen;
  39.        DiaWinCol   :Byte =red+16*Lightgray;
  40.        DiaHeadCol  :Byte =Yellow+16*Lightgray;
  41.        PlotWinCol  :Byte =Crt.blue+16*lightgray;
  42.        PlotHeadCol :Byte =Crt.black+16*lightgray;
  43.  
  44.  
  45. VAR    wok          : INTEGER;
  46.        sel          : BYTE;
  47.        Plot_Win      : WindowType;
  48.        men_main,
  49.        men_Mode     : MenueType;
  50.        Actual_ObjNr : LongInt;
  51.        Actual_StiftNr:Integer;
  52.        UsedLayers    :Layerset;
  53.  
  54. Type
  55. Druckparams =Record
  56.                FileID     :Str10; { enthält GEDDY-PAR}
  57.                PARname    :Str15; { 12 Zeichen       }
  58.                InitString,
  59.                ExitString :Str64;
  60.                Librarypath:Str64;
  61.                Faktor     :System.Real;
  62.                PenSpeed   :Integer;
  63.                LinScal1,
  64.                LinScal2   :System.Real;
  65.                Ursprung   :Koord;
  66.                D_Offset   :Koord; { 0.1 mm Schritte }
  67.                D_Fenster1 :Koord; { 0.1 mm Schritte }
  68.                D_Fenster2 :Koord; { 0.1 mm Schritte }
  69.                D_Adapt    :Boolean;
  70.                D_Mirror   :Boolean;
  71.                D_Portrait :Boolean;
  72.                D_Zurueck  :Boolean;
  73.                D_Farbe    :Byte;
  74.                D_Modus    :Byte;
  75.                LoetStopInc:System.Real;
  76.                D_Absolut  :Boolean;{ Laser }
  77.                D_Position :Koord;  { nur LaserDrucker }
  78.                D_Layers   :Layerset;
  79.                D_PenInfo  :Array[1..MaxLayer+1] of Record
  80.                                                       PenNr   :Byte;
  81.                                                       PenWidth:System.Real;
  82.                                                      end;
  83.                D_Textwidth:System.Real; { Stichbreite zu Schrifthöhe }
  84.              end;
  85.  
  86.  
  87. Const DeviceInit :Str64 ='';
  88.       DeviceExit :Str64 ='';
  89.       ActualParName:Str15='';
  90.       DWGopen    :Boolean=false;
  91.       DevMode         :Boolean=false;
  92.     
  93.  
  94. VAR
  95.        wind_Scr,
  96.        Wind_tmp,
  97.        wind_main,
  98.        wind_dir      : WindowType;
  99.        BatchPar      : Druckparams;
  100.        DateInfo      : Bildelement;
  101.  
  102.  
  103.  
  104. Procedure InitColors;
  105.  
  106. PROCEDURE Border;
  107.  
  108. Procedure Abbrechen;
  109.  
  110. Procedure OpenPrOut(Y :Integer;Var TC :Char);
  111.  
  112. Procedure ClosePrOut;
  113.  
  114. Procedure Zeichne(Objekt :Bildelement;MacWert :Macparms);
  115.  
  116. Procedure Change(Var Objekt :Bildelement;MacWert :Macparms);
  117.  
  118. Procedure GetLastKoord;
  119.  
  120. Function Abstand(P1,P2 :Koord):Integer;
  121.  
  122. Function PrepareSearch(Max:Integer):Boolean;
  123.  
  124. Function MinSearch(Max :Integer):Integer;
  125.  
  126. Procedure SelectPen(Stift:Integer);
  127.  
  128. Procedure ZeichneaufBuf(Var Bild :Bildelement;Clearit :Boolean);
  129.  
  130. Procedure ZeichneMAC(Var Objekt:Bildelement);
  131.  
  132. Procedure Title_Line(Y:Integer;S:Str80);
  133.  
  134. Procedure HeadLine(S:Str80);
  135.  
  136. Procedure Line25;
  137.  
  138.  
  139. Procedure Escape;
  140.  
  141. Procedure InitPlotRes(Res:Real);
  142.  
  143. Procedure PlotInit;
  144.  
  145. Procedure Crea_Men;
  146. {===========================================================================}
  147.  
  148. Implementation
  149.  
  150.  
  151. (*$I PLGLOB.INC *)
  152.  
  153. Var PExitSave :Pointer;
  154.  
  155. {$F+} Procedure Pexit;{$F-}
  156. begin
  157.   IF DWGopen then CloseFile(HauptDF);
  158.   ExitProc:=PExitSave;
  159. end;
  160.  
  161. begin
  162.   PExitSave:=ExitProc;
  163.   ExitProc:=@Pexit;
  164.   InitColors;
  165. end.
  166.  
  167.